﻿<%@ Page Language="C#" MasterPageFile="~/MasterPages/MasterPage2.master" AutoEventWireup="true" CodeFile="Admin_ThemQuangCao.aspx.cs" Inherits="ChucNang_Admin_Admin_ThemQuangCao" Title="Untitled Page" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<center><h2>THÊM QUẢNG CÁO</h2>

<table border="0" cellspacing="10" cellpadding="0" width="350px">
            <tr>
                <td colspan="2">
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ErrorMessage="Chỉ nhập số" ControlToValidate="txtViTri" ValidationExpression="^\d+$"></asp:RegularExpressionValidator>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" ErrorMessage="Chỉ nhập số" ControlToValidate="txtCao" ValidationExpression="^\d+$"></asp:RegularExpressionValidator>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator3" runat="server" ErrorMessage="Chỉ nhập số" ControlToValidate="txtRong" ValidationExpression="^\d+$"></asp:RegularExpressionValidator>
                </td>
            </tr>
        	<tr>
        		<td>Vị trí:
        		    <asp:TextBox ID="txtViTri" runat="server" Width="50"></asp:TextBox>    	
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="RequiredFieldValidator" ControlToValidate="txtViTri">*</asp:RequiredFieldValidator>
                </td>        
            </tr>
        	<tr>
        		<td>Cao: 
                    <asp:TextBox ID="txtCao" runat="server" Text='<%# Eval("Height") %>' Width="50"></asp:TextBox> px
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ErrorMessage="RequiredFieldValidator" ControlToValidate="txtCao">*</asp:RequiredFieldValidator>
                </td>        	
        		<td>Rộng:
                    <asp:TextBox ID="txtRong" runat="server" Text='<%# Eval("Width") %>' Width="50"></asp:TextBox> px
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ErrorMessage="RequiredFieldValidator" ControlToValidate="txtRong">*</asp:RequiredFieldValidator>
                </td>
        	</tr>
        	<tr>
        	    <td>Đối tác:</td>
        	    <td>
                    <asp:DropDownList ID="ddlDoiTac" runat="server" DataSourceID="SqlDataSource1" 
                        DataTextField="TenDoiTac" DataValueField="Id">
                    </asp:DropDownList>
                    <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
                        ConnectionString="<%$ ConnectionStrings:SMOConnectionString %>" 
                        SelectCommand="sp_DOITAC_LayTatCa" SelectCommandType="StoredProcedure">
                    </asp:SqlDataSource>
                </td>
        	</tr>
        	<tr>
        		<td colspan="2">Đường dẫn:
                    <asp:FileUpload ID="fuDuongDan" runat="server" /></td>                
        	</tr>
        	<tr>
        		<td>
                    <asp:CheckBox ID="ckHienThi" runat="server" Text="Hiển thị" Checked='<%# Eval("TrangThai") %>' /></td></tr>
            <tr align="center" >
                <td colspan="2">
                    <asp:Button ID="btnThem" runat="server" Text="Thêm" onclick="btnThem_Click" /></td>
            </tr>
        </table>
</center>
</asp:Content>

